<html xmlns="http://www.w3c.org/1999/xhtml"
   xmlns:h="http://java.sun.com/jsf/html"
   xmlns:p="http://primefaces.org/ui">
<h:head>
</h:head>
<h:body>
	<p:commandLink id="logout" actionListener="#{loginBean.logout}"
    style="margin-right:20px;" oncomplete="logout(xhr, status, args)">
    <h:outputText value="logout" />
    </p:commandLink>
   <h:form id="formGauge">
      <p:poll interval="2" update="gauge" />

      <p:meterGaugeChart id="gauge" value="#{gaugeBean.meterGaugeModel}"
         showTickLabels="false" labelHeightAdjust="110"
         intervalOuterRadius="130"
         seriesColors="66cc66, 93b75f, E7E658, cc6666"
         style="width:400px;height:250px" 
         title="Custom Options" label="km/h" />

   </h:form>
</h:body>
<script type="text/javascript">
  //<![CDATA[
  function logout(xhr, status, args) {
    setTimeout(function() {
      window.location = 'login.xhtml';
    }, 500);
  }
//]]>
</script>
</html>